package IC.lir.Instrunction;

public class Register extends Storable 
{
	//negative means dummy register
	private int _index;
	
	public Register(int index) { _index = index; }
	
	public int GetIndex() { return _index; }
	public String toString() 
	{
		return (_index < 0) ? "Rdummy" : String.format("R%d", _index); 
	}
	
	public Register NextRegister() { return new Register(_index + 1); }
}
